package com.bluesky.jwf.component.tab;

import java.io.Serializable;

import com.bluesky.javawebbrowser.domain.html.tags.Tag;
import com.bluesky.jwf.component.event.EventHandler;

/**
 * it is not a component.
 * 
 * @author jack
 * 
 */
public class Tab implements Serializable {
	private String name;
	private Tag content;
	private boolean active;
	
	private Tabs tabs;

	protected EventHandler queryCloseHandler;
	protected EventHandler closeHandler;

	public Tab(String name, Tag content) {
		this.name = name;
		this.content = content;
		this.active = false;
	}

	public Tab(String name, Tag content, EventHandler queryCloseHandler) {
		this.name = name;
		this.content = content;
		this.active = false;
		this.queryCloseHandler = queryCloseHandler;
	}

	public String getName() {
		return name;
	}

	public void setName(String name) {
		this.name = name;
	}

	public Tag getContent() {
		return content;
	}

	public void setContent(Tag content) {
		this.content = content;
	}

	public boolean isActive() {
		return active;
	}

	public void setActive(boolean active) {
		this.active = active;
	}

	public EventHandler getQueryCloseHandler() {
		return queryCloseHandler;
	}

	public void setQueryCloseHandler(EventHandler queryCloseHandler) {
		this.queryCloseHandler = queryCloseHandler;
	}

	public Tabs getTabs() {
		return tabs;
	}

	public void setTabs(Tabs tabs) {
		this.tabs = tabs;
	}

	public EventHandler getCloseHandler() {
		return closeHandler;
	}

	public void setCloseHandler(EventHandler closeHandler) {
		this.closeHandler = closeHandler;
	}

}
